﻿@{
    ViewBag.Title = "模块管理";
    Layout = "~/Views/Shared/_Layout.cshtml";
}
<script src="~/Assets/global/Plugins/jquery-1.11.0.min.js"></script>
@*<script src="~/assets/global/plugins/jstree/dist/jstree.min.js"></script>
<script src="~/Scripts/pages/BsModule/BsModule.js"></script>*@
@section scripts{
    <!-- BEGIN PAGE LEVEL SCRIPTS -->
    @System.Web.Optimization.Scripts.Render("~/assets/global/plugins/jstree/dist/jstree.min.js")
    @System.Web.Optimization.Scripts.Render("~/Scripts/pages/BsModule/BsModule.js")
    <!-- END PAGE LEVEL SCRIPTS -->
    <script>
    </script>
}
<!-- BEGIN PAGE HEADER-->
<h3 class="page-title">
    模块管理
</h3>
<div class="page-bar">
    <ul class="page-breadcrumb">
        <li>
            <i class="fa fa-home"></i>
            <a href="@Url.Action("Index", "Home")">首页</a>
            <i class="fa fa-angle-right"></i>
        </li>
        <li>
            <a href="#">模块管理</a>
        </li>
    </ul>
</div>
<!-- END PAGE HEADER -->
<div class="portlet purple box">
    <div class="portlet-title">
        <div class="caption">
            <i class="fa fa-cogs"></i>
        </div>
        <div class="tools">
            <a href="javascript:;" class="collapse"></a>
        </div>
    </div>
    <div class="portlet-body form tfbox">
        <!-- BEGIN FORM-->
        <form id="form1" action="#" method="post" class="form-horizontal">
            <input id="ID" type="hidden">
            <input id="ParentID" type="hidden">
            <input id="Creator" type="hidden">
            <input id="CreateTime" type="hidden">
            <div class="form-body">
                <div class="row">
                    <div class="col-md-5 tfbox-tree" style="overflow: hidden;">
                        <div class="ctl-p">
                            <div class="form-tree-actions">
                                <a class="btn btn-circle btn-icon-only btn-default" id="addChild" href="javascript:;">
                                    <i class="icon-add">+</i>
                                </a>
                                <a class="btn btn-circle btn-icon-only btn-default" id="delete" href="javascript:;">
                                    <i class="icon-trash"></i>
                                </a>
                            </div>
                            <p class="ui-title">
                                模块树
                                <input type="button" value=" - 收起" class="btn btn-xs red btn-switch" id="J-switch">
                            </p>
                        </div>
                        <div id="treeMain" style="overflow: scroll; overflow-x: hidden;">
                            <div class="" id="treebox">
                                <div id="bs_module_tree"></div>
                            </div>
                        </div>
                    </div>
                    <div class="col-md-7 tfbox-form">
                        <div class="form-group">
                            <label class="col-md-3 control-label">父级&nbsp;&nbsp;</label>
                            <div class="col-md-4">
                                <span id="parent"></span>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-md-3 control-label">模块编码<span class="required" aria-required="true">*</span></label>
                            <div class="col-md-5">
                                <input id="ModuleCode" type="text" class="form-control">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-md-3 control-label">模块名称<span class="required" aria-required="true">*</span></label>
                            <div class="col-md-5">
                                <input id="ModuleName" type="text" class="form-control">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-md-3 control-label">地址&nbsp;&nbsp;</label>
                            <div class="col-md-5">
                                <input id="ModuleUrl" type="text" class="form-control">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-md-3 control-label">序号&nbsp;&nbsp;</label>
                            <div class="col-md-5">
                                <input id="ModuleOrder" type="text" class="form-control" onkeyup="this.value=this.value.replace(/\D/g,'')">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-md-3 control-label">图标&nbsp;&nbsp;</label>
                            <div class="col-md-5">
                                <input id="ModuleIcon" type="text" class="form-control">
                                @*<select id="ModuleIcon" class="form-control form-filter input">
                                        <option value="">请选择</option>
                                        <option value="icon-home">icon-home</option>
                                        <option value="icon-diamond">icon-diamond</option>
                                        <option value="icon-user">icon-user</option>
                                    </select>*@
                            </div>
                        </div>
                        <div class="form-group last">
                            <label class="col-md-3 control-label">备注&nbsp;&nbsp;</label>
                            <div class="col-md-5">
                                <textarea style="height: 100px;" id="Remark" class="form-control" placeholder="请输入备注"></textarea>
                            </div>
                        </div>
                        <div class="form-action">
                            <div class="form-group">
                                <div class="col-md-8">
                                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                    <button id="save" type="submit" class="btn btn-default red">保存</button>
                                    <button id="clear" type="reset" class="btn default">清空</button>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </form>
        <!-- END FORM-->
    </div>
</div>
@section header{
    <style>
        #treebox {
            height: 430px;
        }

        .tfbox .form-body {
            padding: 0 10px;
        }

        .tfbox-tree {
            padding-top: 10px;
            position: relative;
            overflow: auto;
        }

            .tfbox-tree .ui-title {
                font-size: 14px;
                color: #e26a6a;
                font-weight: bold;
            }

        .tfbox-form {
            padding-top: 20px;
            border-left: 1px solid #474747;
            padding-left: 0px;
            padding-right: 0px;
            overflow: hidden;
        }

        .tfbox .control-label {
            line-height: initial;
        }

        .tfbox .checker {
            margin-top: 8px !important;
        }

        .tfbox .ui-text {
            height: 26px;
            display: inline-block;
        }

        .tfbox .form-control-static {
            margin: 0;
        }

        .tfbox .form-action {
            width: 97.5%;
            background: #f5f5f5;
            border-top: 1px solid #e5e5e5;
            text-align: center;
            padding: 20px;
        }

        .tfbox .form-tree-actions {
            text-align: right;
            position: absolute;
            right: 12px;
        }

        .tfbox .icon-add {
            font-size: 16px;
        }

        .tfbox .btn-switch {
            display: inline-block;
        }
    </style>
}
